﻿using PetaPoco;
using System;
using System.ComponentModel.DataAnnotations;
using System.Xml.Linq;

namespace Cxuu.Models;

[TableName("cxuu_article_examine")]
[PrimaryKey("Id", AutoIncrement = true)]
public class ArticleExamine
{
    public int Id { get; set; }
    public int UserId { get; set; }
    public string Examine { get; set; }
    public int PostId { get; set; }
    public int Aid { get; set; }
    public int Status { get; set; }
    public DateTime ExaTime { get; set; }
    public DateTime InsertTime { get; set; }
    public string Remarks { get; set; }
    public int Pass { get; set; }
}

public class ViewArticleExamine
{
    public int Id { get; set; }
    [Display(Name = "审核人ID")]
    public int UserId { get; set; }
    [Display(Name = "审核人")]
    public string Examine { get; set; }
    [Display(Name = "报审人ID")]
    public int PostId { get; set; }
    [Display(Name = "文件ID")]
    public int Aid { get; set; }
    [Display(Name = "审核状态")]
    public int Status { get; set; }
    [Display(Name = "审核时间")]
    public DateTime ExaTime { get; set; }
    [Display(Name = "报审时间")]
    public DateTime InsertTime { get; set; }
    [Display(Name = "审核意见")]
    public string Remarks { get; set; }
    [Display(Name = "提交人")]
    public string NickName { get; set; }
    [Display(Name = "文件标题")]
    public string Title { get; set; }

    [Display(Name = "文件内容")]
    public string Content { get; set; }

    [Display(Name = "提交部门")]
    public string DeptName { get; set; }
    [Display(Name = "审核是否通过")]
    public int Pass { get; set; }

}


public class ArticleExamineQuery : Page<ViewArticleExamine>
{
    public int UserId { get; set; }
    public int PostId { get; set; }
    public int Status { get; set; } = -1;
    public string Remarks { get; set; }
    public int Pass { get; set; } = -1;
    public string NickName { get; set; }
    public string Title { get; set; }
    public string Orderby { get; set; } = "Id desc";
    public int Page { get; set; } = 1;
    public int Limit { get; set; } = 15;
}

public class ViewExamine
{
    public int Id { get; set; }
    public int Aid { get; set; }
    public int UserId { get; set; }
    public string Examine { get; set; }
    public int PostId { get; set; }
    public int Status { get; set; }
    public DateTime ExaTime { get; set; }

    public DateTime InsertTime { get; set; }

    public string Remarks { get; set; }
    public int Pass { get; set; }

    public string NickName { get; set; }

    public string DeptName { get; set; }

}


public class ViewArtExamine
{
    public string Title { get; set; }
    public string Content { get; set; }
    public int ArtId { get; set; }
    public int ArtUserId { get; set; }

}